#include "study.h"

QString Study::getUid() const {
  return uid;
}

void Study::setUid(const QString & value) {
  uid = value;
}

QString Study::getDescr() const {
  return descr;
}

void Study::setDescr(const QString & value) {
  descr = value;
}

QTreeWidgetItem *Study::getTreeItem() const {
  QStringList data = {uid, descr};
  QTreeWidgetItem *item = new QTreeWidgetItem(data);
  foreach (Series s, series) {
    item->addChild(s.getTreeItem());
  }
  return item;
}

void Study::addSeries(const Series & s) {
  series.push_back(s);
}

QString Study::getDate() const {
  return date;
}

void Study::setDate(const QString & value) {
  date = value;
}
